home *** CD-ROM | disk | FTP | other *** search
/ The Netherlands - A Compact World / The Netherlands.iso / chapters / 4.dxr / 00005_send-msg.ls < prev    next >
Encoding:
Text File  |  2004-06-10  |  803 b   |  44 lines

  1. property spriteNum, Pactie, Pmsg
  2.  
  3. on beginSprite me
  4. end
  5.  
  6. on endSprite me
  7. end
  8.  
  9. on mouseEnter me
  10.   if Pactie = #mouseEnter then
  11.     hActie()
  12.   end if
  13. end
  14.  
  15. on mouseDown me
  16.   if Pactie = #mouseDown then
  17.     hActie()
  18.   end if
  19. end
  20.  
  21. on mouseLeave me
  22.   if Pactie = #mouseLeave then
  23.     hActie()
  24.   end if
  25. end
  26.  
  27. on mouseUp me
  28.   if Pactie = #mouseUp then
  29.     hActie()
  30.   end if
  31. end
  32.  
  33. on hActie me
  34.   sendAllSprites(#uit)
  35.   sendAllSprites(#aan, Pmsg)
  36. end
  37.  
  38. on getPropertyDescriptionList me
  39.   propertyList = [:]
  40.   setaProp(propertyList, #Pactie, [#comment: "kies een actie ", #format: #text, #default: #mouseEnter, #range: [#mouseEnter, #mouseDown, #mouseUp, #mouseLeave]])
  41.   setaProp(propertyList, #Pmsg, [#comment: "send een msg naar all de sprites, msg;", #format: #string, #default: "msg"])
  42.   return propertyList
  43. end
  44.